<template>
  <!-- template content -->
</template>

<script>
export default {
  methods: {
    performLogout() {
      logout()
        .then(() => {
          this.$store.commit("logOut");
          uni.showToast({
            title: "退出登录成功",
            icon: "success",
          });
          // 跳转到登录页或首页
          uni.reLaunch({
            url: "/pages/common/login/login",
          });
        })
        .catch((error) => {
          console.error("退出登录失败:", error);
          uni.showToast({
            title: "退出登录失败，请重试",
            icon: "none",
          });
        });
    },
  },
};
</script>
